package com.qys.livesMall.app.user.model.vo.app;

import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.qys.livesMall.app.user.model.enums.UserBalanceLogTypeEnum;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * Created by IntelliJ IDEA.
 * User: dp
 * Date: 2023/06/09
 * Time: 16:34
 * DESCRIPTION: 用户余额变动记录
 */
@Data
public class UserBalanceLogVO {

    @Schema(description = "变动说明")
    @TableField("remark")
    private String remark;

    @Schema(description = "变动前金额")
    @TableField("old_amount")
    private BigDecimal oldAmount;

    @Schema(description = "变动金额")
    @TableField("amount")
    private BigDecimal amount;

    @Schema(description = "类型(0支出,1收入)")
    @TableField("status")
    private Byte status;

    @Schema(description = "订单类型（0商城订单,1商城订单退款,2充值,3后台修改,4提现,5邀请奖励）")
    @TableField("type")
    private UserBalanceLogTypeEnum type;

    @Schema(description = "创建时间")
    @TableField("create_time")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+0")
    private LocalDateTime createTime;
}
